<?php
class Father{
    public $name;
    public function __construct()
    {
        echo "父类构造";
    }
    public function la(){
        echo '出来了';
    }
}
class Son extends Father{
    public function __construct()
    {
        // Father::__construct();
        parent::__construct();
    }
    // 子类调用父类成员
    public function test(){
        $this->la();
    }
}
 
$son=new Son(); 
// $son->name='zhangsan';                              
// echo $son->name;
// // $son->la();
// $son->test();


?>